﻿using Microsoft.VisualStudio.TestTools.UnitTesting;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Anagramme.Contracts.Tests
{
    [TestClass]
    public class TeamTests
    {
        [TestMethod]
        public void SetIdRaisePropertyChanged()
        {
            string actual = string.Empty;
            string expected = "Id";

            Team team = new Team();
            team.PropertyChanged += (s, e) => actual = e.PropertyName;
            team.Id = 3;

            Assert.AreEqual(expected, actual);
        }

        [TestMethod]
        public void SetNameRaisePropertyChanged()
        {
            string actual = string.Empty;
            string expected = "Name";

            Team team = new Team();
            team.PropertyChanged += (s, e) => actual = e.PropertyName;
            team.Name = "test";

            Assert.AreEqual(expected, actual);
        }

        [TestMethod]
        public void SetScoreRaisePropertyChanged()
        {
            string actual = string.Empty;
            string expected = "Score";

            Team team = new Team();
            team.PropertyChanged += (s, e) => actual = e.PropertyName;
            team.Score = 3;

            Assert.AreEqual(expected, actual);
        }
    }
}
